<div class="cmsform">
    <form action="" name="languages" method="post">
<table class="formtable">
<thead>
        <tr><td class="tabletitle"><?php echo $this->t('dich cac ngon ngu cua site') ?></td></tr>
</thead>
<tbody>		
<tr><td>
    <!-- ------------------------- -->
    <div> <?php echo $this->t('chon ngon ngu can dich') ?>:

        <select id="lang" name="lang">
           <?php foreach (H_G::$LANG as $key=>$langItem){
               $tmp = ($key == $this->lg) ? "selected=\"selected\"":"";
               echo "<option value=\"$key\"" .$tmp. ">$langItem</option>";
           }
           ?>

        </select></div><br>
    <table class="languagetable">
        <thead>
            <tr>
                <td width="25px"><?php echo $this->t('sott') ?></td>
                <td width="400px"><?php echo $this->t('tu khoa goc') ?></td>
                <td width="*"><?php echo $this->t('dich sang ngon ngu')." ".H_G::$LANG[$this->lg] ?></td>
            </tr>
        </thead>
        <tbody>
       <?php $i = 0;
            foreach ($this->allKeyword as $key=>$keyword):?>
            <tr>
                <td><?php echo ++$i; ?></td>
                <td><?php echo $key; ?></td>
                <td><input type="text" size="50" value="<?php echo $keyword; ?>" name="translate[<?php echo $key ?>]" ></td>
            </tr>
       <?php endforeach; ?>            
        </tbody>
    </table>
    <!-- ------------------------- -->
</td></tr>
</tbody>
<tfoot>
    <tr><td><button type="submit"><?php echo $this->t('luu va xoa cache') ?></button></td></tr>
</tfoot>
</table>
        </form>
</div>
<?php $this->headScript()->captureStart(); ?>
    $("#lang").change(function(){
        window.location.href = '/cms/languages/<?php echo $this->actionName ?>/lg/'+$(this).val();
    });
<?php $this->headScript()->captureEnd(); ?>

